// ====================================================================
// 	The Main Menu
//
//  (c) 2003, Epic Games, Inc.  All Rights Reserved
//	Updated by Ron Prestenback
// ====================================================================

class TestModMainMenu extends UT2K4GUIPage;


var automated 	GUIButton	b_SpawnTest, b_SpellTest, b_PhysicsTest, b_Quit;
var automated   GUILabel	lb_TestMsg;
var localized   string      TestMsg;

function InitComponent(GUIController MyController, GUIComponent MyOwner)
{
	Super.InitComponent(MyController, MyOwner);
	MyController.bModAuthor = true;
	MyController.SaveConfig();
	lb_TestMsg.Caption = TestMsg;
}

function bool ButtonClick(GUIComponent Sender)
{
	if (Sender == b_SpawnTest)
	{
		Console(Controller.Master.Console).DelayedConsoleCommand("open WF-devtest");
		Controller.CloseAll(false,True);
	}
	else if (Sender == b_SpellTest)
    {
		Console(Controller.Master.Console).DelayedConsoleCommand("open WF-devtest");
		Controller.CloseAll(false,True);
	}
	else if (Sender == b_PhysicsTest)
    {
		Console(Controller.Master.Console).DelayedConsoleCommand("open WF-PhysicsTest");
		Controller.CloseAll(false,True);
	}
    else if (Sender == b_Quit);
		Controller.OpenMenu(Controller.GetQuitPage());

	return true;
}


defaultproperties
{

	Begin Object class=GUILabel name=lbTestMsg
		WinWidth=1
		WinLeft=0
		WinTop=0
		Caption="WarFactory Dev Testing"
		TextColor=(R=255,G=255,B=255)
	End Object

	Begin Object class=GUIButton Name=bSpawnTest
	    FontScale=FNS_Small
		StyleName="TextButton"
		Caption="Spawn Test"
        CaptionEffectStylename="TextButtonEffect"
        CaptionAlign=TXTA_Left
		Hint="dystopia-style repossesion"
		OnClick=ButtonClick
		WinWidth=0.574135
		WinHeight=0.075000
		WinLeft=0.433406
		WinTop=0.705859
		bFocusOnWatch=true
        TabOrder=1
		bUseCaptionHeight=true
	End Object

	Begin Object class=GUIButton Name=bSpellTest
	    FontScale=FNS_Small
		StyleName="TextButton"
		Caption="Spell Test"
        CaptionEffectStylename="TextButtonEffect"
        CaptionAlign=TXTA_Left
		Hint="test spellcasting"
		OnClick=ButtonClick
		WinWidth=0.580478
		WinHeight=0.075000
		WinLeft=0.434477
		WinTop=0.800327
		bFocusOnWatch=true
        TabOrder=2
		bUseCaptionHeight=true
	End Object

	Begin Object class=GUIButton Name=bPhysicsTest
	    FontScale=FNS_Small
		StyleName="TextButton"
		Caption="Physics Test"
        CaptionEffectStylename="TextButtonEffect"
        CaptionAlign=TXTA_Left
		Hint="test physics"
		OnClick=ButtonClick
		WinWidth=0.580478
		WinHeight=0.075000
		WinLeft=0.434477
		WinTop=0.800327
		bFocusOnWatch=true
        TabOrder=3
		bUseCaptionHeight=true
	End Object

	Begin Object Class=GUIButton Name=QuitButton
	    FontScale=FNS_Small
		StyleName="TextButton"
		Caption="Exit UT2004"
        CaptionEffectStylename="TextButtonEffect"
        CaptionAlign=TXTA_Left
		Hint="Exit the game"
		OnClick=ButtonClick
		WinWidth=0.526767
		WinHeight=0.075000
		WinLeft=0.424711
		WinTop=0.887567
		bFocusOnWatch=true
        TabOrder=6
		bUseCaptionHeight=true
	End Object

	b_SpellTest=bSpellTest
	b_SpawnTest=bSpawnTest
	b_PhysicsTest=bPhysicsTest
	b_Quit=QuitButton
	lb_TestMsg=lbTestMsg;

	WinWidth=1.0
	WinHeight=1.0
	WinTop=0.0
	WinLeft=0.0

	bRenderWorld=False
	bAllowedAsLast=true
	bDisconnectOnOpen=true
	TestMsg="WarFactory Dev Testing"
}
